import { VantComponent } from '../common/component';
VantComponent({
  classes: ['title-class'],
  props: {
    listData: Object,
    fileCdnUrl:String,
    index: Number
  },
  methods: {
    previewImg: function previewImg(event){
      let imgList = event.currentTarget.dataset.list.ImageList,index=event.currentTarget.dataset.index;
      let list= imgList.length?imgList:[] ;
      list.forEach((item,idx)=>{
        list[idx]=`${this.data.fileCdnUrl}/${item}`;
      })
      wx.previewImage({
        current: list[index], // 当前显示图片的http链接
        urls: list // 需要预览的图片http链接列表
      })
    }
  }
});
